﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

using RFMobile.Database;

namespace RFMobile
{
    public partial class newResponsibleScreen : Form
    {
        public newResponsibleScreen()
        {
            InitializeComponent();

            for (Int32 i = DateTime.Now.Year; i >= 1920; i--)
            {
                this.comboBox3.Items.Add(i);
                this.comboBox4.Items.Add(i);
            }

            this.ShowDialog();
        }

        private Boolean IsFormEmpty()
        {
            if (textBox1.Text != "" && textBox2.Text != "" && textBox3.Text != "" && textBox4.Text != "" && textBox5.Text != "" && textBox7.Text != "" && textBox8.Text != "")
            {
                return (true);
            }

            return (false);
        }

        private void menuItem2_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        private void menuItem1_Click(object sender, EventArgs e)
        {
            String tag_responsible = new System.Random().Next(13499421, 79752999).ToString();

            this.textBox1.Text = tag_responsible;
        }

        private void menuItem5_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        private void menuItem8_Click(object sender, EventArgs e)
        {
            menuItem9_Click(sender, e);
        }

        private void menuItem9_Click(object sender, EventArgs e)
        {
            textBox1.Text = "";
            textBox2.Text = "";
            textBox3.Text = "";
            textBox5.Text = "";
            textBox7.Text = "";
            comboBox1.SelectedIndex = -1;
            comboBox2.SelectedIndex = -1;
            comboBox3.SelectedIndex = -1;
        }

        private void menuItem10_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        private void menuItem11_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void textBox7_TextChanged(object sender, EventArgs e)
        {

        }

        private void textBox6_TextChanged(object sender, EventArgs e)
        {

        }

        private void menuItem6_Click(object sender, EventArgs e)
        {
           
        }
    }
}